﻿using System;
using Nethereum.HdWallet;
using Org.BouncyCastle.Utilities.Encoders;

namespace BlockchainCrypto
{
    class HDWallet
    {
        public static void Main()
        {
            var words = "hamster all enroll craft achieve analyst success carry choice artefact exit tonight";
            var wallet = new Wallet(words, null, "m/44'/206'/0'/0/x");
            Console.WriteLine(wallet.Seed);
            var account = wallet.GetAccount(0);
            Console.WriteLine(account.PrivateKey);
            Console.WriteLine(account.Address);
            var address = Hex.Decode(account.Address[2..]);
            Console.WriteLine(Bech32Engine.Encode("atp", address));
        }
    }
}
